package com.lsu.factory.experiment;

import java.awt.BorderLayout;

import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JTextField;

/**
 * @author wsuo
 */
public class FactoryFrame extends JFrame{
	private JButton btn1, btn2, btn3;
	private JTextField txt2, txt3, txt4, txt5;
	private JLabel l2, l3, l4, l5;
	private JPanel p1, p2;
	
	private FactoryFrame(){
		super("打印凭证");
		btn1 = new JButton("工商银行");
		btn2 = new JButton("建设银行");
		btn3 = new JButton("中国银行");
		
		txt2 = new JTextField(15);
		txt3 = new JTextField(15);
		txt4 = new JTextField(15);
		txt5 = new JTextField(15);
		
		l2 = new JLabel("存款人姓名：");
		l4 = new JLabel("口存款金额：");
		l5 = new JLabel("口口口余额：");
		l3 = new JLabel("口口口账号：");
		
		p1 = new JPanel();
		p2 = new JPanel();
		
		p1.add(l2);
		p1.add(txt2);
		p1.add(l3);
		p1.add(txt3);
		p1.add(l4);
		p1.add(txt4);
		p1.add(l5);
		p1.add(txt5);
		p2.add(btn1);
		p2.add(btn2);
		p2.add(btn3);
		
		this.add(p1);
		this.add(p2, BorderLayout.SOUTH);
		this.setSize(320, 180);
		this.setResizable(false);
		this.setVisible(true);
		this.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
	}

	public static void main(String[] args) {
		new FactoryFrame();
	}
}
